<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="UTF-8">
        <meta name="viewport" content="width=device-width, initial-scale=1.0">
        <meta http-equiv="X-UA-Compatible" content="ie=edge">
        <title>Document</title>
    </head>
    <body>
        <button id="start">开始</button>
        <button id="end">停</button>
        <h1 id="txt">请开始抽奖，最高奖品十万人民币</h1>

        <script>
            var list=['兰博基尼五元优惠券','法拉利五元优惠券','保时捷五元优惠券','十万人民币','一万人民币','一千人民币','一百人民币'];
            var start=document.getElementById('start');
            var end=document.getElementById('end');
            var txt=document.getElementById('txt');
            var timer;
            start.onclick=function(){
                clearInterval(timer)
               timer=setInterval(function(){
                    var n=parseInt(Math.random()*list.length);
                    txt.innerHTML=list[n];
               },100)
            }
            end.onclick=function(){
                clearInterval(timer)
            }
        </script>
    </body>
</html>